Skip to content

Temporarily disable SPM tests run#299

Merged
maratal merged 1 commit intomainfrom
295-disable-SPM-tests-run
Jun 19, 2025
Merged

Temporarily disable SPM tests run#299
maratal merged 1 commit intomainfrom
295-disable-SPM-tests-run

Conversation

@maratal
Copy link
Copy Markdown
Collaborator

@maratal maratal commented Jun 18, 2025

Addresses #295

This will allow to stop tests hanging on CI until a better solution will show up.

Related PR - #297

Summary by CodeRabbit

  • Chores
    • Increased the minimum deployment target for iOS and tvOS to version 16.
    • Temporarily disabled a test step in the continuous integration workflow due to intermittent issues.
  • Tests
    • Added a 2-minute time limit to all unit test suites.
    • Set a 10-minute time limit for the integration test suite.

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Jun 18, 2025

Walkthrough

This update increases the minimum iOS and tvOS deployment targets to version 16, adds suite-level time limit annotations to all major test suites (mostly 2 minutes, 10 minutes for integration tests), and temporarily disables the swift test step in the CI workflow due to intermittent hangs, referencing a related issue.

Changes

File(s) Change Summary
.github/workflows/check.yaml Disabled (commented out) the swift test step in CI; added comment referencing intermittent CI hangs
Package.swift Increased minimum deployment target for iOS and tvOS from 14 to 16
Tests/AblyChatTests/ChatAPITests.swift
Tests/AblyChatTests/DefaultChatClientTests.swift
Tests/AblyChatTests/DefaultMessagesTests.swift
Tests/AblyChatTests/DefaultRoomLifecycleManagerTests.swift
Tests/AblyChatTests/DefaultRoomOccupancyTests.swift
Tests/AblyChatTests/DefaultRoomReactionsTests.swift
Tests/AblyChatTests/DefaultRoomTests.swift
Tests/AblyChatTests/DefaultRoomsTests.swift
Tests/AblyChatTests/SubscriptionStorageTests.swift
Annotated each test suite with @Suite(.timeLimit(.minutes(2))) to enforce a 2-minute execution limit
Tests/AblyChatTests/IntegrationTests.swift Updated suite annotation to include a 10-minute time limit: @Suite(.tags(.integration), .timeLimit(.minutes(10)))

Sequence Diagram(s)

sequenceDiagram
    participant Developer
    participant CI
    participant TestSuite

    Developer->>CI: Push code / PR
    CI->>CI: Build with warnings as errors
    Note over CI: (swift test step is skipped/commented out)
    alt Local or manual test run
        Developer->>TestSuite: Run test suite
        TestSuite-->>Developer: Enforce per-suite time limits (2 or 10 mins)
    end
Loading

Possibly related PRs

  • ably/ably-chat-swift#61: Refactors the same test suites to a new testing framework; both PRs modify test suite configurations.
  • ably/ably-chat-swift#142: Splits build and test steps in the workflow; both PRs adjust the build-and-test CI process.

Suggested reviewers

  • umair-ably

Poem

In the warren where tests now run,
Rabbits race, their work soon done.
Two minutes to hop, or ten if you please,
No more endless loops—just carrot and ease!
CI takes a nap, swift test on hold,
While platforms grow up, brave and bold. 🐇✨

✨ Finishing Touches
  • 📝 Generate Docstrings
🧪 Generate Unit Tests
  • Create PR with Unit Tests
  • Post Copyable Unit Tests in Comment
  • Commit Unit Tests in branch 295-disable-SPM-tests-run

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Explain this complex logic.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai explain this code block.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and explain its main purpose.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR.
  • @coderabbitai generate sequence diagram to generate a sequence diagram of the changes in this PR.
  • @coderabbitai auto-generate unit tests to generate unit tests for this PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

@github-actions github-actions Bot temporarily deployed to staging/pull/299/AblyChat June 18, 2025 15:44 Inactive
@maratal maratal marked this pull request as ready for review June 18, 2025 15:58
Copy link
Copy Markdown

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 0

🧹 Nitpick comments (1)
.github/workflows/check.yaml (1)

95-97: Temporarily disable SPM tests with clear re-enable criteria

Commenting out the swift test step addresses CI hangs temporarily. Add a TODO or milestone reference (e.g., “Re-enable after #295 is resolved”) to ensure this workaround is revisited and removed once the root cause is fixed.

📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between f95eaa0 and a7945ef.

📒 Files selected for processing (12)
  • .github/workflows/check.yaml (1 hunks)
  • Package.swift (1 hunks)
  • Tests/AblyChatTests/ChatAPITests.swift (1 hunks)
  • Tests/AblyChatTests/DefaultChatClientTests.swift (1 hunks)
  • Tests/AblyChatTests/DefaultMessagesTests.swift (1 hunks)
  • Tests/AblyChatTests/DefaultRoomLifecycleManagerTests.swift (1 hunks)
  • Tests/AblyChatTests/DefaultRoomOccupancyTests.swift (1 hunks)
  • Tests/AblyChatTests/DefaultRoomReactionsTests.swift (1 hunks)
  • Tests/AblyChatTests/DefaultRoomTests.swift (1 hunks)
  • Tests/AblyChatTests/DefaultRoomsTests.swift (1 hunks)
  • Tests/AblyChatTests/IntegrationTests.swift (1 hunks)
  • Tests/AblyChatTests/SubscriptionStorageTests.swift (1 hunks)
🔇 Additional comments (11)
Package.swift (1)

9-10: Ensure downstream compatibility when bumping iOS/tvOS deployment targets

Bumping the minimum deployment targets to iOS 16 and tvOS 16 is a breaking change; please verify that any dependent projects or scripts (e.g., CI configs, Fastlane lanes, CocoaPods specs) are updated accordingly and update the README or other documentation if they reference older platform versions.

Tests/AblyChatTests/ChatAPITests.swift (1)

5-5: Add suite-level time limit for ChatAPITests

The @Suite(.timeLimit(.minutes(2))) annotation imposes a 2-minute cap on this suite. Ensure that all unit test suites use a consistent time limit and that integration tests retain the 10-minute limit.

Tests/AblyChatTests/DefaultRoomTests.swift (1)

5-5: Add suite-level time limit for DefaultRoomTests

Applying @Suite(.timeLimit(.minutes(2))) enforces a 2-minute global timeout. Confirm this aligns with other unit test files to maintain consistency across the test suite.

Tests/AblyChatTests/DefaultRoomReactionsTests.swift (1)

5-5: Add suite-level time limit for DefaultRoomReactionsTests

The 2-minute suite-level timeout is correctly applied here. Please verify that all similar test suites have received the same annotation.

Tests/AblyChatTests/DefaultMessagesTests.swift (1)

5-5: Suite-level time limit added – looks good

The 2-minute cap is consistent with the other unit suites and will help surface hangs quickly without being overly strict.

Tests/AblyChatTests/SubscriptionStorageTests.swift (1)

4-4: Suite-level time limit added – looks good

The new 2-minute limit aligns with the broader test policy and should not impact legitimate runs.

Tests/AblyChatTests/DefaultRoomLifecycleManagerTests.swift (1)

5-5: Suite-level time limit added – looks good

Adding a 2-minute ceiling is appropriate for this extensive but normally fast unit suite.

Tests/AblyChatTests/DefaultRoomOccupancyTests.swift (1)

5-5: Suite-level time limit added – looks good

Matches the project-wide policy; keeps runaway tests in check.

Tests/AblyChatTests/DefaultRoomsTests.swift (1)

5-5: Suite-level time limit added – looks good

Consistent 2-minute limit across unit suites is sensible and should aid CI stability.

Tests/AblyChatTests/DefaultChatClientTests.swift (1)

4-4: ```shell
#!/bin/bash

Search for all Xcode project pbxproj files to verify deployment targets

find . -type f -name project.pbxproj -exec rg -Hn IPHONEOS_DEPLOYMENT_TARGET '{}' + -exec rg -Hn TVOS_DEPLOYMENT_TARGET '{}' +

Locate Swift Package manifest(s)

find . -maxdepth 2 -type f -name Package.swift


</details>
<details>
<summary>Tests/AblyChatTests/IntegrationTests.swift (1)</summary>

`13-13`: **Enforce a 10-minute timeout on integration tests**  
Extending `@Suite(.tags(.integration), .timeLimit(.minutes(10)))` prevents CI hangs during longer scenarios. As above, confirm your deployment targets are now iOS/tvOS 16.0+ to support `timeLimit`. 

You can reuse the same script from the unit tests check to validate the deployment targets.

</details>

</blockquote></details>

</details>

<!-- This is an auto-generated comment by CodeRabbit for review status -->

@lawrence-forooghian
Copy link
Copy Markdown
Collaborator

@maratal there are all sorts of unrelated changes in this PR (changing iOS version, adding time limit); please can you remove?

@maratal
Copy link
Copy Markdown
Collaborator Author

maratal commented Jun 19, 2025

@maratal there are all sorts of unrelated changes in this PR (changing iOS version, adding time limit); please can you remove?

done @lawrence-forooghian

@maratal maratal merged commit b08d00e into main Jun 19, 2025
41 checks passed
@maratal maratal deleted the 295-disable-SPM-tests-run branch June 19, 2025 18:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants